//
//  LHAFNetworkTool.h
//  MVC
//
//  Created by dllo on 15/11/6.
//  Copyright © 2015年 蓝鸥科技.李贺. All rights reserved.
//

#import <Foundation/Foundation.h>

typedef NS_ENUM(NSUInteger, LHResponseStyle) {
    LHJSON,
    LHXML,
    LHData,
};

@interface LHAFNetworkTool : NSObject

+ (void)getUrl:(NSString *)url
          body:(id)body
      response:(LHResponseStyle)style
requestHeadFile:(NSDictionary *)headFile
       success:(void (^)(NSURLSessionDataTask *task, id resposeObject))success
       failure:(void (^)(NSURLSessionDataTask *task, NSError *error))failure;

+ (void)postUrl:(NSString *)url
           body:(id)body
       response:(LHResponseStyle)style
requestHeadFile:(NSDictionary *)headFile
        success:(void (^)(NSURLSessionDataTask *task, id responseObject))success
        failure:(void (^)(NSURLSessionDataTask *task, NSError *error))failure;

@end
